package com.android1608.administrator.encryption;


import android.support.v7.app.AppCompatActivity;
import android.os.Bundle;
import android.util.Base64;
import android.util.Log;

public class Base64Activity extends AppCompatActivity {
    String data = "小小熊";

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_base64);

        byte[] encode = Base64.encode(data.getBytes(), Base64.DEFAULT);

        String str = "5L2g";
        Base64.decode(str.getBytes(),Base64.DEFAULT);
        Log.d("flag", "---------->onCreate: " );

    }
}
